﻿<%@ Page Language="C#" MasterPageFile="~/Site.Master" AutoEventWireup="true"
    CodeBehind="Login.aspx.cs" Inherits="Ecommerce.Web.Cliente.Login" %>

<asp:Content ID="Content1" ContentPlaceHolderID="HeadContent" runat="server">
    <script src="../Scripts/jquery.maskedinput-1.3.min.js" type="text/javascript"></script>
    <script type="text/javascript">
        $(document).ready(function () {
            $("#<%=txtCPFCNPJ.ClientID%>").mask(
                '99999999999?9999999',
                { placeholder: " " }
            );
        });

        $(document).ready(function () {
            $('input').keypress(function (e) {
                var code = null;
                code = (e.keyCode ? e.keyCode : e.which);
                return (code == 13) ? false : true;
            });
        });
    </script>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="TopoContent" runat="server">
    <asp:HiddenField ID="hddTipoUsuario" runat="server" />
    <div class="tit_tela">
        Identificação
    </div>
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="MainContent" runat="server">
    <div class="miolo_carrinho_b">
        <div class="miolo_box_carrinho_inf_b">
            <div class="box_checkout">
                <div class="box_passos">
                    <div class="number_passo1">
                    </div>
                    <div class="txt_box_passos">
                        Cadastre-se ou faça o login</div>
                </div>
                <div class="txt_coluna_checkout">
                    <p>
                        <strong>Primeira compra?</strong><br />
                        Informe seu CPF ou CNPJ:
                    </p>
                    <div class="table_checkout">
                        <table width="310" border="0">
                            <tr>
                                <td width="50%" class="box_medio">
                                    <asp:TextBox ID="txtCPFCNPJ" runat="server" CssClass="box_medio_txt" MaxLength="18"></asp:TextBox>
                                </td>
                            </tr>
                            <tr>
                                <td>
                                    <asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server"
                                        ControlToValidate="txtCPFCNPJ" 
                                        ValidationGroup="PrimeiraCompra" 
                                        ErrorMessage="Informe um CPF ou um CNPJ">
                                    </asp:RequiredFieldValidator>
                                    <asp:CustomValidator ID="cvCpfCnpj" runat="server" 
                                        ValidationGroup="PrimeiraCompra" ErrorMessage="CustomValidator" 
                                        ControlToValidate="txtCPFCNPJ" 
                                        onservervalidate="cvCpfCnpj_ServerValidate">
                                    </asp:CustomValidator>
                                </td>
                            </tr>
                        </table>
                    </div>
                    <p><a href="#">SAC - Serviço de atendimento ao cliente</a></p>
                </div>
                <div class="txt_coluna_checkout">
                    <p>
                        <strong>Já possui cadastro?</strong>
                    </p>
                    <div class="table_checkout">
                        <table width="320" border="0">
                            <tr>
                                <td>Email</td>
                            </tr>
                            <tr>
                                <td class="box_medio">
                                    <asp:TextBox ID="txtEmail" runat="server" Width="220" MaxLength="100" CssClass="box_medio_txt"></asp:TextBox>
                                </td>
                            </tr>
                            <tr>
                                <td align="left">
                                    <asp:RequiredFieldValidator ID="RequiredFieldValidator4" runat="server" ErrorMessage="Informe o email" ControlToValidate="txtEmail" ValidationGroup="Lembrar"></asp:RequiredFieldValidator>
                                    <asp:RegularExpressionValidator ID="RegularExpressionValidator2" runat="server" 
                                        ErrorMessage="Informe um email válido" ControlToValidate="txtEmail" 
                                        ValidationExpression="\w+([-+.']\w+)*@\w+([-.]\w+)*\.\w+([-.]\w+)*" ValidationGroup="Lembrar"></asp:RegularExpressionValidator>
                                    <asp:RequiredFieldValidator ID="RequiredFieldValidator2" runat="server" ErrorMessage="Informe o email" ControlToValidate="txtEmail" ValidationGroup="Login"></asp:RequiredFieldValidator>
                                    <asp:RegularExpressionValidator ID="RegularExpressionValidator1" runat="server" 
                                        ErrorMessage="Informe um email válido" ControlToValidate="txtEmail" 
                                        ValidationExpression="\w+([-+.']\w+)*@\w+([-.]\w+)*\.\w+([-.]\w+)*" ValidationGroup="Login"></asp:RegularExpressionValidator>
                                </td>
                            </tr>
                            <tr>
                                <td>
                                    Senha
                                </td>
                            </tr>
                            <tr>
                                <td class="box_medio">
                                    <asp:TextBox ID="txtSenha" runat="server" CssClass="box_medio_txt" Width="220" TextMode="Password"></asp:TextBox>
                                </td>
                            </tr>
                            <tr>
                                <td>
                                    <asp:RequiredFieldValidator ID="RequiredFieldValidator3" runat="server" ErrorMessage="Informe a senha" ControlToValidate="txtSenha" ValidationGroup="Login"></asp:RequiredFieldValidator>
                                </td>
                            </tr>
                            <tr>
                                <td align="left">
                                    <span id="spErro" runat="server" visible="false" class="spanErro">Login ou senha incorreto</span>
                                </td>
                            </tr>
                        </table>
                    </div>
                        <p>
                            <asp:LinkButton ID="lbLembrarSenha" runat="server" Text="Esqueci minha senha?" ValidationGroup="Lembrar" OnClick="lbLembrarSenha_Click"></asp:LinkButton>
                        </p>
                </div>
                <div class="bt_continue">
                    <div class="txt_menu_c">
                        <asp:LinkButton ID="lbContinue" runat="server" onclick="lbContinue_Click" 
                            ValidationGroup="PrimeiraCompra">Continue</asp:LinkButton>
                     </div>
                </div>
                <div class="bt_login">
                    <div class="txt_menu_c">
                        <asp:LinkButton ID="lbLogin" runat="server" ValidationGroup="Login" 
                            onclick="lbLogin_Click">Login</asp:LinkButton></div>
                </div>
                <div class="separador">
                    <img src="images/spacer.gif" width="1" height="20" /></div>
                    <!--
                <div class="box_passos">
                    <div class="number_passo2">
                    </div>
                    <div class="txt_box_passos">
                        Billing Information</div>
                </div>
                <div class="box_passos">
                    <div class="number_passo3">
                    </div>
                    <div class="txt_box_passos">
                        Shipping Information</div>
                </div>
                <div class="box_passos">
                    <div class="number_passo4">
                    </div>
                    <div class="txt_box_passos">
                        Shipping Method</div>
                </div>
                <div class="box_passos">
                    <div class="number_passo5">
                    </div>
                    <div class="txt_box_passos">
                        Payment Information</div>
                </div>
                <div class="box_passos">
                    <div class="number_passo6">
                    </div>
                    <div class="txt_box_passos">
                        Order Review</div>
                </div>
                -->
            </div>
            <div class="box_checkout_b">
            <!--
                <div class="txt_box_passos_checkout">
                    Your Checkout Progress</div>
                <div class="box_progress">
                    <div class="top_box_progress">
                        <img src="images/spacer.gif" width="1" height="1" /></div>
                    <div class="middle_box_progress">
                        <div class="txt_colunab_checkout">
                            <a href="#">Billing Information<br />
                            </a>
                            <div class="separador_cinza">
                                <img src="images/spacer.gif" width="1" height="1" /></div>
                            <a href="#">Shipping Information<br />
                            </a>
                            <div class="separador_cinza">
                                <img src="images/spacer.gif" width="1" height="1" /></div>
                            <a href="#">Shipping Method<br />
                            </a>
                            <div class="separador_cinza">
                                <img src="images/spacer.gif" width="1" height="1" /></div>
                            <a href="#">Payment Information<br />
                            </a>
                            <div class="separador_cinza">
                                <img src="images/spacer.gif" width="1" height="1" /></div>
                            <a href="#">Order Review</a></div>
                    </div>
                    <div class="bottom_box_progress">
                        <img src="images/spacer.gif" width="1" height="1" /></div>
                </div>
                -->
            </div>
        </div>
        <div class="bottom_box_carrinho_inf">
            <img src="images/spacer.gif" width="1" height="1" /></div>
    </div>
</asp:Content>